<?php
if (get_magic_quotes_gpc() == 1) {

$_REQUEST = array_map("stripslashes", $_REQUEST);
$_GET = array_map("stripslashes", $_GET);
//$_POST = array_map("stripslashes", $_POST);
$_COOKIE = array_map("stripslashes", $_COOKIE);

}

$HTTP_HOST = $_SERVER['HTTP_HOST'];

$config ['domain'] = "http://$HTTP_HOST";

$config ['upload_dir'] = $_SERVER ['DOCUMENT_ROOT'].'/uploads';

$config['db_host']       ='localhost';
$config['db_username']   ='root';
$config['db_password']   ='123';
$config['db_database']   ='blog';


//admin
$config ['admin_root_path'] = '/admin';
$config ['admin_section'] = 'admincp';
$config ['admin_document_root'] = $_SERVER ['DOCUMENT_ROOT'] . $config ['admin_root_path'];

$config ['admin_theme'] = "/default";
$config ['admin_theme_path'] = $_SERVER ['DOCUMENT_ROOT']."/admin/themes";
$config ['admin_function_path'] = $_SERVER ['DOCUMENT_ROOT']."/admin/models";

$config ['admin_js_url'] = $config ['domain'] . "/admin/themes".$config ['admin_theme']."/js";
$config ['admin_css_url'] = $config ['domain'] . "/admin/themes".$config ['admin_theme']."/css";
$config ['admin_images_url'] = $config ['domain'] . "/admin/themes".$config ['admin_theme']."/images";

//client
$config ['client_root_path'] = '/client';
$config ['client_document_root'] = $_SERVER ['DOCUMENT_ROOT'] . $config ['client_root_path'];

$config ['client_theme'] = "/default";
$config ['client_theme_path'] = $_SERVER ['DOCUMENT_ROOT']."/client/themes";
$config ['client_model_path'] = $_SERVER ['DOCUMENT_ROOT']."/client/models";
$config ['client_modules_path'] = $_SERVER ['DOCUMENT_ROOT']."/client/modules";

$config ['client_js_url'] = "/client/themes".$config ['client_theme']."/js";
$config ['client_css_url'] = "/client/themes".$config ['client_theme']."/css";
$config ['client_images_url'] = "/client/themes".$config ['client_theme']."/images";
$config ['client_flash_url'] = "/client/themes".$config ['client_theme']."/flash";
$config ['client_xml_url'] = "/client/themes".$config ['client_theme'];


$config ['site_title']='Web expriences, collections, documents and tools';
$config ['site_description']='Web documents, web expriences, web collections, web tools, linux documents, linux command, linux basic command, how to buil a dinamic website by php, web technology';
$config ['site_keyword']='Web documents, web expriences, web collections, web tools, linux documents, linux command, linux basic command, how to buil a dinamic website by php, web technology';

$config ['page']=1;//page start
$config ['total_article_on_category']=15;//numbers of rows show on category
$config ['total_article_on_admin']=20;//numbers of rows show on admin
include "mysql.php";

$db = new database();
$db->db = array('host'=>$config['db_host'],'user'=>$config['db_username'],'pass'=>$config['db_password'],'db'=>$config['db_database']);
$db->Debug = false;
$db->connect();
$db->query("set names utf8");

?>
